package src 
{
	import flash.display.BitmapData;
	import flash.display.MovieClip;
	
	/**
	 * ...
	 * @author Vitaly Vrublevskyy
	 */
	public class Entity extends MovieClip 
	{
		public static const SIZE:uint = 40;
		private static var offset:uint = 6;
		
		private var _type:uint;
		
		public var column:uint;
		public var row:uint;
		
		public function Entity(column:uint, row:uint):void 
		{
			stop();
			
			this.column = column;
			this.row = row;
			

			
			this.width = this.height = SIZE - offset;
		}
		
		public function positioning():void
		{
			this.x = column * SIZE + offset / 2 ;
			this.y = row * SIZE + offset / 2 ;
		}
		
		public function get type():uint 
		{
			return _type;
		}
		
		public function set type(value:uint):void 
		{
			_type = value;
			//this.type =  
			gotoAndStop(_type);
		}
		
	}

}